//
//  ChangePasswordViewController.m
//  苏州银行
//
//  Created by rimi on 15/8/20.
//  Copyright (c) 2015年 IOS. All rights reserved.
//

#import "SZYHChangePasswordViewController.h"

@interface SZYHChangePasswordViewController ()

@property (nonatomic, strong) UIView       *backImage;

@end

@implementation SZYHChangePasswordViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    [self initializeUserInterface];
}

- (void)initializeUserInterface
{
    _backImage = [[UIView alloc]initWithFrame:self.view.bounds];
    _backImage.backgroundColor = [UIColor blackColor];
    _backImage.alpha = 0;
    [self.view addSubview:_backImage];
    _changePasswordView.layer.position = CGPointMake(self.view.center.x, -600);
    [UIView animateWithDuration:0.5 animations:^{
        _backImage.alpha = 0.7;
        _changePasswordView.layer.position = self.view.center;
    }];
    [self.view addSubview:_changePasswordView];
}
- (IBAction)cancelChangePassword:(id)sender {
    [UIView animateWithDuration:0.5 animations:^{
        _backImage.alpha = 0;
        _changePasswordView.layer.position = CGPointMake(self.view.center.x, 900);
    } completion:^(BOOL finished) {
        [self.view removeFromSuperview];
    }];
}

@end
